<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1">
<title>角色管理 </title>
<link rel="stylesheet" href="/yc/js/noty/jquery.noty.css" type="text/css"/>
<link rel="stylesheet" href="/yc/js/noty/noty_theme_default.css" type="text/css"/>
</head>
<div th:include="shared/css"></div>
<div th:include="shared/js"></div>
<body>
	<div class="container-fluid wrapper-content" >
		<div class="row">
			<div class="col-md-offset-2 col-md-3">
				<div class="panel panel-default">
					<div class="panel-heading">
						<h3 class="panel-title">角色列表</h3>
					</div>
					<div class="panel-body">
						<div id="tree"></div>
					</div>
				</div>
			</div>

			<div class="col-md-5">

				<!-- Nav tabs -->
				<ul class="nav nav-tabs" role="tablist" id="tablist">
					<li role="presentation" class="active">
						<a href="#role-tab"	aria-controls="home" role="tab" data-toggle="tab"><span id="role-tab-title">角色信息</span>
							<span id="loadingRoleImg" style="display:none;"><img src="/yc/img/loading.gif" /></span>
						</a>
					</li>
					<li role="presentation">
						<a href="#user-tab"	aria-controls="profile" role="tab" data-toggle="tab">绑定用户
							<span id="loadingUserImg" style="display:none;"><img src="/yc/img/loading.gif" /></span>
						</a>
					</li>
					<!-- <li role="presentation">
						<a href="#func-tab"	aria-controls="profile" role="tab" data-toggle="tab">功能权限
							<span id="loadingFuncImg" style=""><img src="/yc/img/loading.gif" /></span>
						</a>
					</li> -->
				</ul>

				<div class="tab-content" id="tabcontent">
				
					<div role="tabpanel" class="tab-pane active" id="role-tab">

						<div class="panel panel-default">
							
							<div class="panel-body">
					
								<form class="form-horizontal">

									<input type="hidden" id="role-id" />
									
									<!-- <input type="hidden" id="role-parent-id" /> -->

									<!-- <div class="form-group">
										<label class="col-sm-2 control-label">编号</label>
										<div class="col-sm-10">
											<input type="text" class="form-control" id="code" placeholder="编号">
										</div>
									</div> -->

									<div class="form-group">
										<label class="col-sm-2 control-label">名称</label>
										<div class="col-sm-10">
											<input type="text" class="form-control" id="name" placeholder="名称">
										</div>
										<label class="col-sm-2 control-label">角色编号</label>
										<div class="col-sm-10">
											<input type="text" class="form-control" id="code" placeholder="角色编号" >
										</div>
									</div>
									
									<div class="form-group">
										<label for="demand-desc" class="col-sm-2 control-label">说明</label>
										<div class="col-sm-10">
											<textarea class="form-control" rows="3" id="comment"></textarea>
										</div>
									</div>

									<!-- <div class="form-group">
										<div class="col-sm-offset-2 col-sm-10">
											<div class="checkbox">
												<label> 
													<input type="checkbox" id="activate">状态
												</label>
											</div>
										</div>
									</div> -->

									<div class="form-group">
										<div class="col-sm-offset-2 col-sm-10">
											<p id="function-area">
												<!-- <input type="button" class="btn btn-default" id="show-child"	value="添加类别" /> -->
												<input type="button" class="btn btn-info" id="show-root" value="添加角色" /> 
												<input type="button" class="btn btn-success" id="update" value="  更  新  " /> 
												<input type="button" class="btn btn-warning" id="delete" value="  删  除 " />
											</p>
											<p id="t-root" style="display: none;">
												<input type="button" class="btn btn-primary" id="add-root" value="  保  存  " />
												<input type="button" class="btn btn-default add-cancel" value=" 取  消   " />
											</p>
											<p id="t-child" style="display: none;">
												<input type="button" class="btn btn-primary" id="add-child" value="  保  存  " />
												<input type="button" class="btn btn-default add-cancel" value=" 取  消   " />
											</p>
										</div>
									</div>
									
								</form>
								
							</div>
							
						</div>
						
					</div>
					
					<div role="tabpanel" class="tab-pane" id="user-tab">

						<div class="panel panel-default">
							  
							  <div class="panel-body">
							  
								<form class="form-inline">
		
									<div class="form-group">
		
										<input type="text" id="userName" class="form-control" value="" placeholder="用户手机" />
		
									</div>
		
									<div class="form-group">
		
										<input type="button" class="btn btn-success" onclick="javascript:bindUser();" value="绑定" />
		
									</div>
		
								</form>
		
								<h5>已绑定用户列表</h5>
		
								<ul id="user-ul" class="list-group"></ul>
								
							</div>
							
						</div>
						
					</div>

					<div role="tabpanel" class="tab-pane" id="func-tab">
					
						<div class="panel panel-default">
							  
							  <div class="panel-body">
							  
							  	<p class="text-warning">提示：先绑定一级功能，再绑定二级功能</p>
																
								<input type="hidden" id="func-ids" />
								
								<div id="func-tree"></div>
							</div>
							
						</div>
						
					</div>

					

				</div><!-- end of tab content -->

			</div><!-- end of tab col -->
			
		</div><!-- end of tab row -->

	</div><!-- end of tab container -->
<!-- <script type="text/javascript" src="/hs/js/noty/jquery.noty.js"></script> -->
<script type="text/javascript" src="/yc/js/myjs/myFunction.js"></script>
<script type="text/javascript"	src="/yc/js/myjs/role.index.js"></script>
<!-- <script type="text/javascript"	src="/yc/js/myjs/role.index.func.js"></script> -->
<script type="text/javascript"	src="/yc/js/myjs/role.index.user.js"></script>
<!-- endbuild -->


</body>
</html>